<%@ page language="java" pageEncoding="UTF-8" contentType="text/html; charset=utf-8" errorPage="/error.jsp" isELIgnored="false" %>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-bean" prefix="bean" %>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-html" prefix="html" %>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-logic" prefix="logic" %>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-tiles" prefix="tiles" %>
<%@ taglib uri="http://java.sun.com/jstl/core" prefix="c" %>
<%@ taglib uri="http://java.sun.com/jstl/fmt" prefix="fmt" %>
<%@ taglib uri="http://www.opensymphony.com/oscache" prefix="cache" %>
<%@ taglib uri="http://atleap.blandware.com/taglib" prefix="atleap" %>
<html:xhtml />

<atleap:constants className="com.blandware.atleap.webapp.util.core.WebappConstants" var="CONTENT_LOCALES_COLLECTION_KEY" scope="page" />
<atleap:constants className="com.blandware.atleap.webapp.util.core.WebappConstants" var="HTML_TEXT_FIELD_MAX_LENGTH" />
<%--<atleap:javascript formName="answerOptionForm" staticJavascript="false" dynamicJavascript="true" method="validateForm" cdata="false" />--%>
<atleap:content identifier="information" ignore="true" uri="/questionnaire/answerOption/callCreate" />
<atleap:messages property="answerOptionAlreadyExists" />
<atleap:messages property="ownerNotFound" /><br />
<atleap:form action="questionnaire/answerOption/create" method="POST" validateOnSubmit="false">
    <table cellpadding="0"  cellspacing="0" border="0" class="modificationTable">
		<tr>
			<td colspan="2" align="center">
				<atleap:label property="title" key="questionnaire.answerOption.form.title" colon="false" helpTip="true" />
			</td>
		</tr>
		<atleap:iterator items="${sessionScope[pageScope.CONTENT_LOCALES_COLLECTION_KEY]}" var="contentLocale">
			<tr>
				<th>
					<div class="languageField">
						<atleap:fieldValue valueMap="${contentLocale.title}" var="languageTitle" />
						<c:if test="${empty languageTitle}">
							<c:set var="languageTitle" value="${contentLocale.identifier}" />
						</c:if>
						*&nbsp;<atleap:message key="questionnaire.answerOption.form.language" />:&nbsp;${languageTitle}
					</div>
				</th>
				<td>
					<html:text property="title(${contentLocale.identifier})" maxlength="${pageScope.HTML_TEXT_FIELD_MAX_LENGTH}" styleClass="text" />
				</td>
			</tr>
		</atleap:iterator>
    </table>
    <atleap:submit styleClass="button"><atleap:message key="core.commons.buttons.create" /></atleap:submit>
    <atleap:cancel styleClass="button"><atleap:message key="core.commons.buttons.cancel" /></atleap:cancel>
</atleap:form>
